//
//  LWVistorTableViewController.swift
//  MicroBlog
//
//  Created by 孙程 on 2017/7/17.
//  Copyright © 2017年 孙程. All rights reserved.
//

import UIKit

class LWVistorTableViewController: UITableViewController {
    //是否登录的标识
    var isLogIn:Bool = false
    
    //访客视图
    var vistorView: LWVistorView?
    
    
    //自定义View视图
    override func loadView() {
        if isLogIn {
            super.loadView()
        }else
        {
            vistorView = LWVistorView()
            view = vistorView
            
            //未登录情况下调用nav
            setupNavUI()
            
        }
    }
    
    override func viewDidLoad() {
        super.viewDidLoad()

    }
    //设置导航栏按钮
        private func setupNavUI(){
            navigationItem.leftBarButtonItem = UIBarButtonItem(title: "登录", target: self, action: #selector(logInBtn))
            navigationItem.rightBarButtonItem = UIBarButtonItem(title: "注册", target: self, action: #selector(logInBtn))
        }
    //MARK - 点击事件
    func logInBtn() -> Void {
        print("点击阿尼")
    }


   

}
